package com.nuonuo.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletRequest;

/**
 * @author duan
 * @version 1.0
 * @date 2023/4/12 10:38
 */
@RestController
@RequestMapping(value = "/")
public class HelloController {

    @GetMapping(value = "/sayHello")
    public String sayHello1(HttpServletRequest request) {
        return request.getRequestURI();
    }

    @GetMapping(value = "/api/sayHello")
    public String sayHello2(HttpServletRequest request) {
        return request.getRequestURI();
    }
}
